﻿<%@ Page Language="C#" MasterPageFile="~/Default.Master" AutoEventWireup="true" CodeBehind="GiaTotGanDay.aspx.cs" Inherits="MasterPageGroupF3.GiaTotGanDayHN" Title="Untitled Page" %>
<%@ Import Namespace="DTO" %>
<%@ Import Namespace="BUS" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <ul class="clsmenuul">
        <li><a href="index.aspx">GIÁ TỐT HÔM NAY </a></li>
        <li class="active"><a href="GiaTotGanDay.aspx">GIÁ TỐT GẦN ĐÂY</a> </li>
        <li><a href="ThaoLuan.aspx">THẢO LUẬN</a>&nbsp;</li>
        <li><a href="TroGiup.aspx">TRỢ GIÚP</a> </li>
    </ul>    
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" runat="server">
    <%
        int idCity = 1;
    %>

    <div class="div_LMainInfo ">
        <div class="div_topLBestPrice">
        </div>
        <div id="divRecentDeal">
            <ul class='ul_listBestPrice'>
            <% 
                PRODUCT[] products = PRODUCTBUS.DanhSachSanPhamTheoThanhPho(idCity);
                for (int i = 0; i < products.Count(); i++)
                {
            %>
                <li class='li_ListBP'>
                    <div class='div_topListBP'>
                    </div>
                    <div class='div_bodyListBP'>
                        <div class='div_bodyLineRound'>
                        </div>
                        <div class='div_infoListBP'>
                            <div class='div_LBodyListBP'>
                                <div class='div_TietKiem'>
                                    <strong class='styleText14'>Tiết Kiệm</strong><br />
                                    <strong class='styleText15'><% Response.Write(products[i].RATE_DECREASE.ToString() + "%"); %></strong></div>
                                <div class='divPrice'>
                                    <span class='styleText17'>Giá trị:<strong class='StyleTextGT lineHorizontal styleText13'><% Response.Write(products[i].PRICE.ToString()); %></strong></span><div
                                        class='div_VND GTVND'>
                                        <strong class='styleText16'>VND</strong></div>
                                    <br />
                                    <span class='styleText17 spTietKiem'>Tiết kiệm:<strong class='StyleTextGT styleText13'>
                                    <%                                   
                                        int TietKiem = (int)products[i].PRICE * (int)products[i].RATE_DECREASE / 100;                         
                                        Response.Write(TietKiem.ToString()); 
                                    %>
                                    </strong></span><div
                                        class='div_VND TKVND'>
                                        <strong class='styleText16'>VND</strong></div>
                                </div>
                                <div class='div_infoMoney'>
                                    <div class='div_TextInfoMoney'>
                                        <p class='styleText14'>
                                            <strong>Còn Lại</strong><strong class='strTextVND'>VND</strong></p>
                                        <p class='pGiaTien'>
                                            <strong class='styleText5'>
                                                <%                   
                                                    int ConLai = (int)products[i].PRICE - TietKiem;                     
                                                    Response.Write(ConLai.ToString()); 
                                                %>
                                            </strong></p>
                                    </div>
                                </div>
                                <p class='color9 styleText9 pWasBuyer'>
                                    <strong>4000</strong></p>
                                <p class='pWasBuyer color9 styleText14'>
                                    Người mua giá tốt</p>
                            </div>
                            <div class='div_RBodyListBP'>
                                <p class='pTextInfoList styleText8'>
                                    <a href="ChiTietSanPham.aspx?idProduct=<% Response.Write(products[i].IDPRODUCT);%>">
                                        <% Response.Write(products[i].SLOGAN);%>
                                        </a></p>
                                <div class='div_imgListBP'>
                                    <a href='#'><i class='iChayHang'></i>
                                        <img width='229' height='140' src='<% Response.Write(products[i].IMAGE);%>' />
                                    </a>
                                </div>
                                <p class='styleText13 pDayCity'>
                                    TP Hồ Chí Minh - 01/05/2011</p>
                            </div>
                        </div>
                    </div>
                    <div class='div_bottomListBP'>
                    </div>
                </li>
                <% } %>                                        
            <div class='div_buttonBP' id='divPaging'>
                <div class='div_aListPage' id='div_aListPage'>
                    <span>1</span><a href='#'>2</a>                                        
                </div>
            </div>
            </ul>
        </div>
    </div>
</asp:Content>
